/*
 * CcValue.h
 *
 *  Created on: 2012/04/28
 *      Author: guanxiaoying
 */

#ifndef CCVALUE_H_
#define CCVALUE_H_

extern VOID CcValueInit ( VOID );

extern AST CcValueAddOrign( PSZ pszNum);
extern AST CcValueAddVarValue( AST astType, VARVALUE value );
extern AST CcValueAddFloating( AST astType, DOUBLE value );

extern VARVALUE CcValueGetInteger( AST astValue );
extern DOUBLE CcValueGetFloating( AST astValue );

extern S4 CcValueCompareIdx( AST idx1, AST idx2 );
extern S4 CcValueCompareForTree( PVALUEINFO pst1, PVALUEINFO pst2 );

extern AST CcValueGetZero( AST astType );
extern AST CcValueGetOne( AST astType );
extern AST CcValueGetMaxValue( AST astType );
extern AST CcValueGetMinValue( AST astType );

extern BOOL CcValueIsPositive( AST astValue );
extern BOOL CcValueIsNegative( AST astValue );
extern BOOL CcValueIsZero( AST astValue );
#endif /* CCVALUE_H_ */
